package com.example.myapplication.view.toolbar;

import android.content.Context;

import androidx.recyclerview.widget.RecyclerView;

import com.example.myapplication.R;
import com.example.myapplication.adapter.recycleradaper.RecyclerQuickAdapter;
import com.example.myapplication.adapter.recycleradaper.RecyclerViewHelper;
import com.example.myapplication.decoration.StickHeaderDecoration;

public class ItemAdapter extends RecyclerQuickAdapter<String> implements StickHeaderDecoration.StickHeaderInterface {
    public ItemAdapter(Context context) {
        super(context, R.layout.item_coordinator);
    }

    @Override
    protected void convert(int viewType, RecyclerViewHelper helper, String s) {
        helper.setText(R.id.text, s);
    }

    @Override
    public boolean isStick(int position) {
        return position % 10 == 0;
    }

    @Override
    public void onClickHeader(RecyclerView.ViewHolder viewHolder, int position, float x, float y) {

    }
}
